/**
 * LogKaiyuanAgentMapper.java
 * Copyright(C) 1949++ 中华人民共和国
 * 深圳市盛开互联网金融顾问有限公司.
 * All rights reserved.
 * E-mail:server@skjr.net
 * SKDate:2017-11-16 17:28:58
 */
package com.huamao.zh.service;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

import com.huamao.zh.base.PageWrapper;
import com.huamao.zh.constants.KaiyuanAgentType;
import com.huamao.zh.model.LogKaiyuanAgent;

public interface LogKaiyuanAgentService {
	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	LogKaiyuanAgent add(LogKaiyuanAgent logKaiyuanAgent) throws Exception;

	LogKaiyuanAgent add(int type, int fromId, int agentId, String orderNo, int scoreType, BigDecimal preKaiyuan,
			int kaiyuanType, BigDecimal getKaiyuan, String remark) throws Exception;

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	LogKaiyuanAgent addSelective(LogKaiyuanAgent logKaiyuanAgent) throws Exception;

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	int delete(Map<String, Object> map);

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	int update(LogKaiyuanAgent logKaiyuanAgent) throws Exception;

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	int updateSelective(LogKaiyuanAgent logKaiyuanAgent) throws Exception;

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	LogKaiyuanAgent get(Integer id);

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	PageWrapper<LogKaiyuanAgent> search(PageWrapper<LogKaiyuanAgent> pageWrapper);

	/**
	 * 功能说明： Author： SKDate:2017-11-16 17:28:58
	 */
	List<LogKaiyuanAgent> queryList(Map<String, Object> map);

	LogKaiyuanAgent sumLogKaiyuanAgent(KaiyuanAgentType type, Integer agentId, String orderNo, BigDecimal preCash,
			BigDecimal cash, String remark) throws Exception;

	LogKaiyuanAgent subtractLogKaiyuanAgent(KaiyuanAgentType type, Integer agentId, String orderNo, BigDecimal preCash,
			BigDecimal cash, String remark) throws Exception;
}